define(function(require, exports){
	exports.onMain = function( boot, data, app ) {
		var con = app.getContainer({
			scenes: 'main',
			full: false,
			sitelist: false,
			setup_btn: false,
			title: LANG('图文创意模板列表'),
			type: 'sidebar'
		});

		con.createBusiness(data.name, 'ptc/action/template.list', function(mod, notFirst){
				mod.reset();
		});
	};

	exports.onEdit = function( boot, data, app ) {
		var con = app.getContainer({
			scenes: 'main',
			full: false,
			sitelist: false,
			setup_btn: false,
			title: LANG('图文创意模板编辑'),
			type: 'sidebar'
		});

		var id = +data.param;
		con.createBusiness(data.name, 'ptc/action/template.edit', function(mod, notFirst){
			mod.reset();
			if(id) {
				mod.load(id);
			}
		});
	};

	exports.onImport = function( boot, data, app ) {
		var con = app.getContainer({
			scenes: 'main',
			full: false,
			sitelist: false,
			setup_btn: false,
			title: LANG('图文创意模板导入')
			//type: 'sidebar'
		});

		con.createBusiness(data.name, 'ptc/action/template.import', function(mod, notFirst){
			mod.reset();
		});
	};
});